﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

using JM.JCY.Proxy;
using JM.JCY.BusinessEntity;
using NCS.IConnect.ApplicationContexts;
using JM.JCY.Common;
using System.Web.UI.HtmlControls;
using System.Data;

namespace JM.JCY.SharePointComponent.Layouts.SharePointComponent
{
    public partial class PreviewNews : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            Response.Cache.SetExpires(DateTime.Now.AddSeconds(3));
            if (!IsPostBack)
            {
                if (Session["NewsData"] != null)
                {
                    NewsDataSet.T_AnnouncementDataTable dt = (NewsDataSet.T_AnnouncementDataTable)Session["NewsData"];
                    NewsDataSet.T_AnnouncementRow row = dt[0];
                    this.lblSummary.Text = row.Summary;
                    this.imgPic.ImageUrl = "/"+row.ImageUrl;
                    this.lblCreatedDate.Text = row.CREATED_TIME.ToString(JCYConstant.Date_Format_CN);
                }
            }
        }
        
    }
}
